aboutdialog: Improve example image
authorMatthias Clasen <mclasen@redhat.com>
Fri, 26 Feb 2021 14:30:36 +0000 (09:30 -0500)
committerEmmanuele Bassi <ebassi@gnome.org>
Thu, 11 Mar 2021 16:37:33 +0000 (16:37 +0000)
Use our logo, and update the copyright years.

docs/reference/gtk/images/aboutdialog.png
docs/tools/gtk-logo.png [new file with mode: 0644]
docs/tools/widgets.c

index dd324b18803d9e08dabb13cab2d3b68e237c4410..e4a8d880203f81c27a2eff8035b9912f6c47adff 100644 (file)
Binary files a/docs/reference/gtk/images/aboutdialog.png and b/docs/reference/gtk/images/aboutdialog.png differ
diff --git a/docs/tools/gtk-logo.png b/docs/tools/gtk-logo.png
new file mode 100644 (file)
index 0000000..28e546b
Binary files /dev/null and b/docs/tools/gtk-logo.png differ
index 56cf2eb8d238d8e4d42729937a529c9b4573bfba..474cdd3bbe5e7665c0912fc509d5947ccc6c35a0 100644 (file)
@@ -878,19 +878,27 @@ create_about_dialog (void)
     "and many more...",
     NULL
   };
+  GFile *file;
+  GdkTexture *logo;
+
+  file = g_file_new_for_path ("docs/tools/gtk-logo.png");
+  logo = gdk_texture_new_from_file (file, NULL);
 
   widget = gtk_about_dialog_new ();
   g_object_set (widget,
                 "program-name", "GTK Code Demos",
                 "version", PACKAGE_VERSION,
-                "copyright", "© 1997-2013 The GTK Team",
+                "copyright", "© 1997-2021 The GTK Team",
                 "website", "http://www.gtk.org",
                 "comments", "Program to demonstrate GTK functions.",
-                "logo-icon-name", "help-about",
+                "logo", logo,
                 "title", "About GTK Code Demos",
                 "authors", authors,
                NULL);
-  gtk_window_set_icon_name (GTK_WINDOW (widget), "help-about");
+
+  g_object_unref (logo);
+  g_object_unref (file);
+
   return new_widget_info ("aboutdialog", widget, ASIS);
 }